3.3.84 \(\int \frac {d+e x}{x (a+c x^2)} \, dx\)

Optimal. Leaf size=49 \[ -\frac {d \log \left (a+c x^2\right )}{2 a}+\frac {e \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{\sqrt {a} \sqrt {c}}+\frac {d \log (x)}{a} \]

________________________________________________________________________________________

Rubi [A]  time = 0.04, antiderivative size = 49, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 4, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {801, 635, 205, 260} \begin {gather*} -\frac {d \log \left (a+c x^2\right )}{2 a}+\frac {e \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{\sqrt {a} \sqrt {c}}+\frac {d \log (x)}{a} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(d + e*x)/(x*(a + c*x^2)),x]

[Out]

(e*ArcTan[(Sqrt[c]*x)/Sqrt[a]])/(Sqrt[a]*Sqrt[c]) + (d*Log[x])/a - (d*Log[a + c*x^2])/(2*a)

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rule 635

Int[((d_) + (e_.)*(x_))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Dist[d, Int[1/(a + c*x^2), x], x] + Dist[e, Int[x/
(a + c*x^2), x], x] /; FreeQ[{a, c, d, e}, x] &&  !NiceSqrtQ[-(a*c)]

Rule 801

Int[(((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_)))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Int[ExpandIntegrand[(
(d + e*x)^m*(f + g*x))/(a + c*x^2), x], x] /; FreeQ[{a, c, d, e, f, g}, x] && NeQ[c*d^2 + a*e^2, 0] && Integer
Q[m]

Rubi steps

\begin {align*} \int \frac {d+e x}{x \left (a+c x^2\right )} \, dx &=\int \left (\frac {d}{a x}+\frac {a e-c d x}{a \left (a+c x^2\right )}\right ) \, dx\\ &=\frac {d \log (x)}{a}+\frac {\int \frac {a e-c d x}{a+c x^2} \, dx}{a}\\ &=\frac {d \log (x)}{a}-\frac {(c d) \int \frac {x}{a+c x^2} \, dx}{a}+e \int \frac {1}{a+c x^2} \, dx\\ &=\frac {e \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{\sqrt {a} \sqrt {c}}+\frac {d \log (x)}{a}-\frac {d \log \left (a+c x^2\right )}{2 a}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 49, normalized size = 1.00 \begin {gather*} -\frac {d \log \left (a+c x^2\right )}{2 a}+\frac {e \tan ^{-1}\left (\frac {\sqrt {c} x}{\sqrt {a}}\right )}{\sqrt {a} \sqrt {c}}+\frac {d \log (x)}{a} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(d + e*x)/(x*(a + c*x^2)),x]

[Out]

(e*ArcTan[(Sqrt[c]*x)/Sqrt[a]])/(Sqrt[a]*Sqrt[c]) + (d*Log[x])/a - (d*Log[a + c*x^2])/(2*a)

________________________________________________________________________________________

IntegrateAlgebraic [F]  time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {d+e x}{x \left (a+c x^2\right )} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

IntegrateAlgebraic[(d + e*x)/(x*(a + c*x^2)),x]

[Out]

IntegrateAlgebraic[(d + e*x)/(x*(a + c*x^2)), x]

________________________________________________________________________________________

fricas [A]  time = 0.42, size = 109, normalized size = 2.22 \begin {gather*} \left [-\frac {c d \log \left (c x^{2} + a\right ) - 2 \, c d \log \relax (x) + \sqrt {-a c} e \log \left (\frac {c x^{2} - 2 \, \sqrt {-a c} x - a}{c x^{2} + a}\right )}{2 \, a c}, -\frac {c d \log \left (c x^{2} + a\right ) - 2 \, c d \log \relax (x) - 2 \, \sqrt {a c} e \arctan \left (\frac {\sqrt {a c} x}{a}\right )}{2 \, a c}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)/x/(c*x^2+a),x, algorithm="fricas")

[Out]

[-1/2*(c*d*log(c*x^2 + a) - 2*c*d*log(x) + sqrt(-a*c)*e*log((c*x^2 - 2*sqrt(-a*c)*x - a)/(c*x^2 + a)))/(a*c),
-1/2*(c*d*log(c*x^2 + a) - 2*c*d*log(x) - 2*sqrt(a*c)*e*arctan(sqrt(a*c)*x/a))/(a*c)]

________________________________________________________________________________________

giac [A]  time = 0.15, size = 40, normalized size = 0.82 \begin {gather*} \frac {\arctan \left (\frac {c x}{\sqrt {a c}}\right ) e}{\sqrt {a c}} - \frac {d \log \left (c x^{2} + a\right )}{2 \, a} + \frac {d \log \left ({\left | x \right |}\right )}{a} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)/x/(c*x^2+a),x, algorithm="giac")

[Out]

arctan(c*x/sqrt(a*c))*e/sqrt(a*c) - 1/2*d*log(c*x^2 + a)/a + d*log(abs(x))/a

________________________________________________________________________________________

maple [A]  time = 0.06, size = 39, normalized size = 0.80 \begin {gather*} \frac {e \arctan \left (\frac {c x}{\sqrt {a c}}\right )}{\sqrt {a c}}+\frac {d \ln \relax (x )}{a}-\frac {d \ln \left (c \,x^{2}+a \right )}{2 a} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((e*x+d)/x/(c*x^2+a),x)

[Out]

-1/2*d*ln(c*x^2+a)/a+e/(a*c)^(1/2)*arctan(1/(a*c)^(1/2)*c*x)+1/a*d*ln(x)

________________________________________________________________________________________

maxima [A]  time = 1.25, size = 38, normalized size = 0.78 \begin {gather*} \frac {e \arctan \left (\frac {c x}{\sqrt {a c}}\right )}{\sqrt {a c}} - \frac {d \log \left (c x^{2} + a\right )}{2 \, a} + \frac {d \log \relax (x)}{a} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)/x/(c*x^2+a),x, algorithm="maxima")

[Out]

e*arctan(c*x/sqrt(a*c))/sqrt(a*c) - 1/2*d*log(c*x^2 + a)/a + d*log(x)/a

________________________________________________________________________________________

mupad [B]  time = 1.41, size = 216, normalized size = 4.41 \begin {gather*} \frac {d\,\ln \relax (x)}{a}-\frac {d\,\ln \left (a\,e\,\sqrt {-a^3\,c}+3\,a^2\,c\,d-a^2\,c\,e\,x+3\,c\,d\,x\,\sqrt {-a^3\,c}\right )}{2\,a}-\frac {d\,\ln \left (a\,e\,\sqrt {-a^3\,c}-3\,a^2\,c\,d+a^2\,c\,e\,x+3\,c\,d\,x\,\sqrt {-a^3\,c}\right )}{2\,a}+\frac {e\,\ln \left (a\,e\,\sqrt {-a^3\,c}-3\,a^2\,c\,d+a^2\,c\,e\,x+3\,c\,d\,x\,\sqrt {-a^3\,c}\right )\,\sqrt {-a^3\,c}}{2\,a^2\,c}-\frac {e\,\ln \left (a\,e\,\sqrt {-a^3\,c}+3\,a^2\,c\,d-a^2\,c\,e\,x+3\,c\,d\,x\,\sqrt {-a^3\,c}\right )\,\sqrt {-a^3\,c}}{2\,a^2\,c} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((d + e*x)/(x*(a + c*x^2)),x)

[Out]

(d*log(x))/a - (d*log(a*e*(-a^3*c)^(1/2) + 3*a^2*c*d - a^2*c*e*x + 3*c*d*x*(-a^3*c)^(1/2)))/(2*a) - (d*log(a*e
*(-a^3*c)^(1/2) - 3*a^2*c*d + a^2*c*e*x + 3*c*d*x*(-a^3*c)^(1/2)))/(2*a) + (e*log(a*e*(-a^3*c)^(1/2) - 3*a^2*c
*d + a^2*c*e*x + 3*c*d*x*(-a^3*c)^(1/2))*(-a^3*c)^(1/2))/(2*a^2*c) - (e*log(a*e*(-a^3*c)^(1/2) + 3*a^2*c*d - a
^2*c*e*x + 3*c*d*x*(-a^3*c)^(1/2))*(-a^3*c)^(1/2))/(2*a^2*c)

________________________________________________________________________________________

sympy [B]  time = 1.47, size = 321, normalized size = 6.55 \begin {gather*} \left (- \frac {d}{2 a} - \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right ) \log {\left (x + \frac {- 12 a^{2} c d \left (- \frac {d}{2 a} - \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right )^{2} + 2 a^{2} e^{2} \left (- \frac {d}{2 a} - \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right ) + 6 a c d^{2} \left (- \frac {d}{2 a} - \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right ) - 2 a d e^{2} + 6 c d^{3}}{a e^{3} + 9 c d^{2} e} \right )} + \left (- \frac {d}{2 a} + \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right ) \log {\left (x + \frac {- 12 a^{2} c d \left (- \frac {d}{2 a} + \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right )^{2} + 2 a^{2} e^{2} \left (- \frac {d}{2 a} + \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right ) + 6 a c d^{2} \left (- \frac {d}{2 a} + \frac {e \sqrt {- a^{3} c}}{2 a^{2} c}\right ) - 2 a d e^{2} + 6 c d^{3}}{a e^{3} + 9 c d^{2} e} \right )} + \frac {d \log {\relax (x )}}{a} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)/x/(c*x**2+a),x)

[Out]

(-d/(2*a) - e*sqrt(-a**3*c)/(2*a**2*c))*log(x + (-12*a**2*c*d*(-d/(2*a) - e*sqrt(-a**3*c)/(2*a**2*c))**2 + 2*a
**2*e**2*(-d/(2*a) - e*sqrt(-a**3*c)/(2*a**2*c)) + 6*a*c*d**2*(-d/(2*a) - e*sqrt(-a**3*c)/(2*a**2*c)) - 2*a*d*
e**2 + 6*c*d**3)/(a*e**3 + 9*c*d**2*e)) + (-d/(2*a) + e*sqrt(-a**3*c)/(2*a**2*c))*log(x + (-12*a**2*c*d*(-d/(2
*a) + e*sqrt(-a**3*c)/(2*a**2*c))**2 + 2*a**2*e**2*(-d/(2*a) + e*sqrt(-a**3*c)/(2*a**2*c)) + 6*a*c*d**2*(-d/(2
*a) + e*sqrt(-a**3*c)/(2*a**2*c)) - 2*a*d*e**2 + 6*c*d**3)/(a*e**3 + 9*c*d**2*e)) + d*log(x)/a

________________________________________________________________________________________